import request from '@/utils/request'

// 查询易告知管理列表
export function listInform (query) {
  return request({
    url: '/system/inform/list',
    method: 'get',
    params: query
  })
}

export function getPerson(person_id) {
  return request({
    url: '/member/member/getPerson',
    method: 'get',
    params: {
      person_id
    }
  })
}

export function getEmailByName(memberName) {
  return request({
    url: '/member/member/getEmailByName',
    method: 'get',
    params: {
      memberName
    }
  })
}

export function findName(names) {
  return request({
    url: '/system/inform/findName',
    method: 'get',
    params: {
      names
    }
  })
}



// 查询易告知管理详细
export function getInform (informId) {
  return request({
    url: '/system/inform/' + informId,
    method: 'get'
  })
}

// 新增易告知管理
export function addInform (data) {
  return request({
    url: '/system/inform',
    method: 'post',
    data: data
  })
}



// 修改易告知管理
export function updateInform (data) {
  return request({
    url: '/system/inform',
    method: 'put',
    data: data
  })
}

// 删除易告知管理
export function delInform (informId) {
  return request({
    url: '/system/inform/' + informId,
    method: 'delete'
  })
}



// 邮件发送
export function sendTextMail (to, subject, text, m_id) {
  return request({
    url: '/mail/sendTextMail/',
    // url: '/system/inform/',
    params: {
      to, subject, text, m_id
    }
  })
}

// 新增納稅信息
export function addNashuixinxi (data) {
  return request({
    url: '/nashuixinxi/nashuixinxi ',
    method: 'post',
    data:data
  })
}
